Click the R Project menu in the top right and then click ‘New project…’
If you want to create a folder (directory) for your project to live in at the same time (recommended), click ‘New Directory’
Click ‘New Project’
Set where you want your new project directory to be added: e.g. I generally keep all of my R projects in a parent directory called ‘r’. Type in a name for your project and then click ‘Create Project’.
Check that your working directory has now changed to the project you just created; you should also see your .Rproj file in the ‘Files’ tab of the Files/Viewer pane and the name of your project in the top right hand corner
Click the button in the top left that looks like a white square with a plus sign over it, then click “R Script” (or R Markdown if you wish to use R Markdown)
You should now have a new, untitled R script open in your Script pane. Remember to save this script.
Reopening your R project after closing.
You can either open your R project directly by going to the directory in your computer’s files system (e.g. file explorer), or you can open Rstudio and open it from the recently used list in the top right corner.